.class Lcom/esfile/screen/recorder/player/DuVideoView$b;
.super Ljava/lang/Object;
.source "DuVideoView.java"

# interfaces
.implements Landroid/media/MediaPlayer$OnPreparedListener;


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/esfile/screen/recorder/player/DuVideoView;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation


# instance fields
.field final synthetic a:Lcom/esfile/screen/recorder/player/DuVideoView;


# direct methods
.method constructor <init>(Lcom/esfile/screen/recorder/player/DuVideoView;)V
    .locals 0

    .line 1
    iput-object p1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method


# virtual methods
.method public onPrepared(Landroid/media/MediaPlayer;)V
    .locals 4

    .line 1
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    const/4 v1, 0x2

    invoke-static {v0, v1}, Lcom/esfile/screen/recorder/player/DuVideoView;->g(Lcom/esfile/screen/recorder/player/DuVideoView;I)I

    .line 2
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->k(Lcom/esfile/screen/recorder/player/DuVideoView;)Landroid/media/MediaPlayer$OnPreparedListener;

    move-result-object v0

    if-eqz v0, :cond_0

    .line 3
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->k(Lcom/esfile/screen/recorder/player/DuVideoView;)Landroid/media/MediaPlayer$OnPreparedListener;

    move-result-object v0

    iget-object v1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v1}, Lcom/esfile/screen/recorder/player/DuVideoView;->l(Lcom/esfile/screen/recorder/player/DuVideoView;)Landroid/media/MediaPlayer;

    move-result-object v1

    invoke-interface {v0, v1}, Landroid/media/MediaPlayer$OnPreparedListener;->onPrepared(Landroid/media/MediaPlayer;)V

    .line 4
    :cond_0
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->m(Lcom/esfile/screen/recorder/player/DuVideoView;)Landroid/widget/MediaController;

    move-result-object v0

    if-eqz v0, :cond_1

    .line 5
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->m(Lcom/esfile/screen/recorder/player/DuVideoView;)Landroid/widget/MediaController;

    move-result-object v0

    const/4 v1, 0x1

    invoke-virtual {v0, v1}, Landroid/widget/MediaController;->setEnabled(Z)V

    .line 6
    :cond_1
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-virtual {p1}, Landroid/media/MediaPlayer;->getVideoWidth()I

    move-result v1

    invoke-static {v0, v1}, Lcom/esfile/screen/recorder/player/DuVideoView;->a(Lcom/esfile/screen/recorder/player/DuVideoView;I)I

    .line 7
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-virtual {p1}, Landroid/media/MediaPlayer;->getVideoHeight()I

    move-result p1

    invoke-static {v0, p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->c(Lcom/esfile/screen/recorder/player/DuVideoView;I)I

    .line 8
    iget-object p1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->n(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result p1

    if-eqz p1, :cond_2

    .line 9
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-virtual {v0, p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->seekTo(I)V

    .line 10
    :cond_2
    sget v0, Landroid/os/Build$VERSION;->SDK_INT:I

    const/16 v1, 0x17

    const/high16 v2, -0x40800000    # -1.0f

    if-lt v0, v1, :cond_3

    .line 11
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->o(Lcom/esfile/screen/recorder/player/DuVideoView;)F

    move-result v0

    cmpl-float v1, v0, v2

    if-eqz v1, :cond_3

    .line 12
    iget-object v1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-virtual {v1, v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->setPlaySpeed(F)V

    .line 13
    :cond_3
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->p(Lcom/esfile/screen/recorder/player/DuVideoView;)F

    move-result v0

    .line 14
    iget-object v1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v1}, Lcom/esfile/screen/recorder/player/DuVideoView;->q(Lcom/esfile/screen/recorder/player/DuVideoView;)F

    move-result v1

    cmpl-float v3, v0, v2

    if-eqz v3, :cond_4

    cmpl-float v2, v1, v2

    if-eqz v2, :cond_4

    .line 15
    iget-object v2, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-virtual {v2, v0, v1}, Lcom/esfile/screen/recorder/player/DuVideoView;->a(FF)V

    .line 16
    :cond_4
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->a(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result v0

    const/4 v1, 0x3

    if-eqz v0, :cond_7

    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->b(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result v0

    if-eqz v0, :cond_7

    .line 17
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-virtual {v0}, Landroid/view/SurfaceView;->getHolder()Landroid/view/SurfaceHolder;

    move-result-object v0

    iget-object v2, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v2}, Lcom/esfile/screen/recorder/player/DuVideoView;->a(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result v2

    iget-object v3, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v3}, Lcom/esfile/screen/recorder/player/DuVideoView;->b(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result v3

    invoke-interface {v0, v2, v3}, Landroid/view/SurfaceHolder;->setFixedSize(II)V

    .line 18
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->c(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result v0

    iget-object v2, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v2}, Lcom/esfile/screen/recorder/player/DuVideoView;->a(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result v2

    if-ne v0, v2, :cond_8

    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->d(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result v0

    iget-object v2, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v2}, Lcom/esfile/screen/recorder/player/DuVideoView;->b(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result v2

    if-ne v0, v2, :cond_8

    .line 19
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->e(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result v0

    if-ne v0, v1, :cond_5

    .line 20
    iget-object p1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-virtual {p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->start()V

    .line 21
    iget-object p1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->m(Lcom/esfile/screen/recorder/player/DuVideoView;)Landroid/widget/MediaController;

    move-result-object p1

    if-eqz p1, :cond_8

    .line 22
    iget-object p1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->m(Lcom/esfile/screen/recorder/player/DuVideoView;)Landroid/widget/MediaController;

    move-result-object p1

    invoke-virtual {p1}, Landroid/widget/MediaController;->show()V

    goto :goto_0

    .line 23
    :cond_5
    iget-object v0, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-virtual {v0}, Lcom/esfile/screen/recorder/player/DuVideoView;->isPlaying()Z

    move-result v0

    if-nez v0, :cond_8

    if-nez p1, :cond_6

    iget-object p1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-virtual {p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->getCurrentPosition()I

    move-result p1

    if-lez p1, :cond_8

    .line 24
    :cond_6
    iget-object p1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->m(Lcom/esfile/screen/recorder/player/DuVideoView;)Landroid/widget/MediaController;

    move-result-object p1

    if-eqz p1, :cond_8

    .line 25
    iget-object p1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->m(Lcom/esfile/screen/recorder/player/DuVideoView;)Landroid/widget/MediaController;

    move-result-object p1

    const/4 v0, 0x0

    invoke-virtual {p1, v0}, Landroid/widget/MediaController;->show(I)V

    goto :goto_0

    .line 26
    :cond_7
    iget-object p1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-static {p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->e(Lcom/esfile/screen/recorder/player/DuVideoView;)I

    move-result p1

    if-ne p1, v1, :cond_8

    .line 27
    iget-object p1, p0, Lcom/esfile/screen/recorder/player/DuVideoView$b;->a:Lcom/esfile/screen/recorder/player/DuVideoView;

    invoke-virtual {p1}, Lcom/esfile/screen/recorder/player/DuVideoView;->start()V

    :cond_8
    :goto_0
    return-void
.end method
